-- card: 12512 from stack: in -- bmap block id: 15974 -- flags: 4000 -- background id: 2175 -- name: TryIt ----- HyperTalk script ----- on closeCard put "Auto Insurance" &return& "Electricity" &return& "House Payment" into card field "expenseDemo" put "$346.57" &return& "$52.84" &return& "$746.00" into card field "amountDemo" hide button "demo" repeat with i = 5 to 11 if the visible of card field i = true then hide card field i end repeat end closeCard on mouseUp show card field "buttonHelp" show button "demo" repeat until the mouseClick end repeat get the mouseLoc hide button "demo" hide card field "buttonHelp" if item 1 of it > 235 and item 1 of it < 275 and item 2 of it >306 and item 2 of it < 339 then send mouseUp to button "Go Back" end mouseUp on arrowKey direction if direction is "right" then go last card else pass arrowKey end if end arrowkey -- part 1 (field) -- low flags: 01 -- high flags: 4002 -- rect: left=20 top=56 right=297 bottom=181 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 3 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: expenseDemo ----- HyperTalk script ----- on mouseDown demoItems end mouseDown on demoItems put (item 2 of the mouseLoc - 39) div 16 into whichLine put the short name of the target into whichField if line whichLine of card field whichField is empty then exit demoItems get line whichLine of card field whichField repeat with i = 1 to the number of lines in card field "demoData" if it = item 1 of line i of card field "demoData" then put line i of card field "demoData" into theList exit repeat end if end repeat if it = "Auto Insurance" then put line 1 of card field "amountDemo" into item 2 of theList if it = "Electricity" then put line 2 of card field "amountDemo" into last word of item 4 of theList if it = "House Payment" then put line 3 of card field "amountDemo" into item 2 of theList if item 3 of theList = "Every Month" then put "," & card field "monthList" of card "Expenses" after theList put the mouseloc into listHere put item 1 of listHere + 1 into horiz put item 2 of listHere - 10 into vert get the number of items in theList put vert + (it * 17) into length if length > 314 then subtract (length - 324) from vert get PopUpMenu(theList, 1, vert, horiz) put item it of theList into sayWhat if it = 1 then show card field "itemHelp" repeat until the mouseClick end repeat hide card field "itemHelp" else if it > 2 then show card field "monthHelp" repeat until the mouseClick end repeat hide card field "monthHelp" else if it = 2 then show card field "nothing" repeat until the mouseClick end repeat hide card field "nothing" end if end if end demoItems on mouseUp end mouseUp -- part 2 (field) -- low flags: 01 -- high flags: 4002 -- rect: left=180 top=56 right=297 bottom=256 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 65535 -- font id: 3 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: amountDemo ----- HyperTalk script ----- on mouseUp end mouseUp -- part 3 (field) -- low flags: 01 -- high flags: 0000 -- rect: left=256 top=56 right=297 bottom=417 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 3 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: expense2Demo ----- HyperTalk script ----- on mouseUp end mouseUp -- part 4 (field) -- low flags: 01 -- high flags: 4002 -- rect: left=416 top=56 right=297 bottom=492 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 65535 -- font id: 3 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: amount2Demo ----- HyperTalk script ----- on mouseUp end mouseUp -- part 6 (field) -- low flags: 81 -- high flags: 0000 -- rect: left=55 top=124 right=259 bottom=368 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 3 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: demoData -- part 7 (field) -- low flags: 81 -- high flags: 2004 -- rect: left=105 top=43 right=179 bottom=427 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 3 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: itemHelp ----- HyperTalk script ----- on mouseUp hide the target end mouseUp -- part 8 (field) -- low flags: 81 -- high flags: 2004 -- rect: left=105 top=43 right=118 bottom=427 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 3 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: monthHelp ----- HyperTalk script ----- on mouseUp hide the target end mouseUp -- part 9 (field) -- low flags: 81 -- high flags: 2004 -- rect: left=105 top=44 right=103 bottom=427 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 3 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: nothing ----- HyperTalk script ----- on mouseUp hide the target end mouseUp -- part 10 (button) -- low flags: 00 -- high flags: 2000 -- rect: left=195 top=18 right=37 bottom=280 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: demoEnter Item ----- HyperTalk script ----- on mouseUp show card field "demoEnter" repeat until the mouseClick end repeat get the mouseLoc hide card field "demoEnter" if item 1 of it > 235 and item 1 of it < 275 and item 2 of it >306 and item 2 of it < 339 then send mouseUp to button "Go Back" end mouseUp -- part 11 (field) -- low flags: 81 -- high flags: 2004 -- rect: left=105 top=44 right=119 bottom=427 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 3 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: demoEnter ----- HyperTalk script ----- on mouseUp hide the target end mouseUp -- part 12 (button) -- low flags: 00 -- high flags: 2000 -- rect: left=280 top=18 right=37 bottom=370 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: demoDelete Item ----- HyperTalk script ----- --Copyright ©1988 - Scott McGilliard - all rights reserved on mouseUp if the optionKey is down then answer "Delete all the DEMO expense items?" with "Cancel" or "DEMO" if it = "DEMO" then put empty into card field "expenseDemo" put empty into card field "amountDemo" else exit mouseUp end if else set loc of msg to 18,15 put "Please click on the DEMO item you want deleted" set cursor to 3 repeat until the mouse is down end repeat put item 1 of the mouseLoc into temp1 put item 2 of the mouseLoc into temp2 if temp1 > 181 and temp1 < 256 then hide msg exit mouseUp end if if temp1 < 20 or temp1 >417 then hide msg exit mouseUp end if if temp1 >= 20 and temp1 <= 181 then put "expenseDemo" into whichField else if temp1 >= 256 and temp1 <= 417 then put "expense2Demo" into whichField end if end if put (temp2 - 39) div 16 into whichLine put line whichLine of card field whichField into whatExpense if whatExpense ≠ empty then answer "Delete expense item..." && whatExpense &&"?" with "Cancel" or "OK" if it = "Cancel" then put empty into whatExpense end if if whatExpense = empty then hide msg exit mouseUp end if set cursor to 4 set loc of msg to 19,106 put "Please wait" delete line whichLine of card field whichField delete line whichLine of card field "amountDemo" hide msg end if end mouseUp -- part 13 (button) -- low flags: 00 -- high flags: 2000 -- rect: left=370 top=18 right=37 bottom=482 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: demoChange Amount ----- HyperTalk script ----- --Copyright ©1988 - Scott McGilliard - all rights reserved on mouseUp set loc of msg to 18,15 put "Please click on the DEMO amount you want changed" set cursor to 3 set numberFormat to "0.00" repeat until the mouse is down end repeat hide msg put item 1 of the mouseLoc into temp1 put item 2 of the mouseLoc into temp2 if temp1 >= 180 and temp1 <= 256 then put "expenseDemo" into whichField put "amountDemo" into whichField2 else if temp1 >= 416 and temp1 <= 492 then put "expense2Demo" into whichField put "amount2Demo" into whichField2 else hide msg exit mouseUp end if end if put (temp2 - 39) div 16 into whichLine put line whichLine of card field whichField into whatExpense put line whichLine of card field whichField2 into newAmount if whatExpense = empty then hide msg exit mouseUp end if ask "Please enter the new amount for" && whatExpense with newAmount if it = empty then hide msg exit mouseUp else if char 1 of it = "$" then delete char 1 of it add 0 to it put "$" & it into newAmount if it = newAmount then hide msg exit mouseUp end if end if set cursor to 4 set loc of msg to 19,106 put "Please wait" put newAmount into line whichLine of card field whichField2 hide msg end mouseUp -- part 14 (button) -- low flags: 00 -- high flags: 2000 -- rect: left=238 top=308 right=336 bottom=273 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: Go Back ----- HyperTalk script ----- on mouseUp visual venetian blinds to gray visual venetian blinds pop card end mouseUp -- part 15 (field) -- low flags: 81 -- high flags: 2004 -- rect: left=105 top=43 right=247 bottom=427 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 3 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: buttonHelp ----- HyperTalk script ----- on mouseUp hide button "demo" hide the target end mouseUp -- part 16 (button) -- low flags: 80 -- high flags: 0000 -- rect: left=203 top=142 right=162 bottom=226 -- title width / last selected line: 0 -- icon id / first selected line: 16816 / 16816 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: demo ----- HyperTalk script ----- on mouseUp hide button "demo" hide card field "buttonHelp" end mouseUp -- part 17 (button) -- low flags: 00 -- high flags: 0000 -- rect: left=310 top=311 right=335 bottom=444 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: New Button ----- HyperTalk script ----- on mouseUp end mouseUp -- part 18 (button) -- low flags: 00 -- high flags: 0000 -- rect: left=52 top=15 right=40 bottom=152 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: Feb ----- HyperTalk script ----- on mouseUp end mouseUp on mouseDown put the mouseloc into listHere put item 1 of listHere + 1 into horiz put item 2 of listHere - 10 into vert put card field "monthList" of card "Expenses" into theList get PopUpMenu(theList, 1, vert, horiz) if it >= 1 then show card field "monthHelp" repeat until the mouseClick end repeat hide card field "monthHelp" end if end mouseDown -- part 19 (field) -- low flags: 81 -- high flags: 2004 -- rect: left=30 top=108 right=292 bottom=247 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 3 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: viewDemo ----- HyperTalk script ----- on mouseUp hide card field "viewDemo" end mouseUp -- part contents for card part 6 ----- text ----- AUTO INSURANCE,$346.57,February,August ELECTRICITY,variable,January - $69.12,February - $52.84,March - $46.05,April - $48.16,May - $52.76,June - $42.64,July - $46.10,August - $43.23,September - $56.65,October - $49.34,November - $47.42,December - $53.41 HOUSE PAYMENT,$746.00,Every Month -- part contents for card part 7 ----- text ----- This is a demo or you would have been asked "Automatic cost adjustment for this expense?" If you then clicked on yes The Stabilizer would make a card and ask you for the data needed to set up the yearly estimates for the next year's budget. If you already had a cost adjustment card for this expense then you would have gone to that card. -- part contents for card part 8 ----- text ----- This is a demo or you would have gone to the card for that month. If you chose "Every Month" then you would have gotten a message that you can't go to every month at once. -- part contents for card part 9 ----- text ----- You can't do anything with the amount from the pop-up menu. You can't do anything with "Variable" either. -- part contents for card part 11 ----- text ----- This is a demo or you would have been asked to "Please enter an expense item" followed by the sequence of dialog boxes designed to gather all the expense data for that item. -- part contents for card part 15 ----- text ----- This is a Demo card. But if it was not a Demo then if you clicked on the "House" button you would go to the "Home" card. If you clicked on the "?" button you would go to the "Help Index" card. If you clicked on the "Year Totals" button you would go to the "Year Totals" card. If you clicked on the button you would go to the "All Expenses" card, unless you are in the help section. Then you would return to the card where you clicked on a "Help" button. If you click on the "Go Back" button you will go back to the card you were at just before this one. -- part contents for card part 1 ----- text ----- Auto Insurance Electricity House Payment -- part contents for card part 2 ----- text ----- $346.57 $52.84 $746.00 -- part contents for card part 19 ----- text ----- You can view all the basic info for an expense item by holding the mouse down on an expense name in any list. (You can also hold the mouse down on the name of the month at the top of the card.) In a second or two a list will pop-up which is also a menu. You can use it to go to a month card or to make or go to an estimated expense card.